<div class="row">
	<div class="col-md-12">
		<div class="bid-payout-total" style="border: 1px solid #ddd; padding: 10px; margin-bottom: -1px; border-top: none;">
			<span>待收款项合计：</span>
			<b class="text-danger">${(data.planInMoneyTotal?string('currency'))!'-'}</b>
		</div>
	</div>
	<div class="col-md-12">
		<table class="table table-bordered" style="border: none;">
			<tr>
				<#if roles.canPlanMoneyIn && roles.contractMain>
				<th class="text-center" width="45">变更</th>
				</#if>
				<th class="text-center" width="60">状态</th>
				<th class="text-center" width="190">收款金额（元）</th>
				<th class="text-center" width="110">收款日期</th>
				<th class="text-center">收款单位</th>
				<th class="text-center" width="110">收款负责人</th>
				<th class="text-center">收款事项</th>
				<th class="text-center">备注</th>
				<th class="text-center" style="min-width: 160px;">变更记录</th>
			</tr>
			<#if data.payinPlans??> <#list data.payinPlans as pim>
			<tr class="${(pim.back?? && pim.back)?string('money-gave-back',((pim.overDate)?string('text-danger','')))}">
				<#if roles.canPlanMoneyIn && roles.contractMain>
				<td class="text-center">
					<#if !(pim.back?? && pim.back)>
					<a href="javascript:;" class="icon-random text-primary edit-payin-plan" data-id="${pim.id}"></a>
					</#if>
				</td>
				</#if>
				<td class="text-center get-back-money-by-plan"><#if pim.back?? && pim.back> 已收款<#else>未收 </#if></td>
				<td class="text-center">${(pim.total?string('currency'))!'-'}</td>
				<td class="text-center">${(pim.backTime?string('yyyy-MM-dd'))!'-'}</td>
				<td class="text-center">${pim.moneyFrom!'-'}</td>
				<td class="text-center">${pim.header.name!'-'}</td>
				<td class="">${pim.reason!'-'}</td>
				<td class="">${pim.remark!'-'}</td>
				<td>
					<!--  -->
					<#if pim.changeReason??>
					<!--  -->
					<#list pim.changeReason?split('++--++') as r>
					<!--  -->
					<#assign d=r?split('--++--')>
					<!--  -->
					<small class="text-danger"> ${r_index+1}、${d[0]!''} （${d[1]!''}） </small>
					<small>
						<br>
						${(d[2]?replace('\n','
						<br>
						'))!''}
					</small>
					<br>
					</#list>
					<!--  -->
					<#else> - </#if>
				</td>
			</tr>
			</#list> </#if>
		</table>
	</div>
</div>

